package com.lyc.business.interfaces.controller.resignationGuidelines;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.lyc.business.interfaces.facade.resignationGuidelines.ResignationGuidelinesService;
import com.lyc.common.entity.ResignationGuidelinesReq;
import com.lyc.common.entity.ResignationGuidelinesVo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

/**
 * 离职指引控制类
 * @Author 李大神仙
 * @Date 2024/2/23 20:45
 * @Version 1.0
 */

@Api(tags = "离职指引")
@RestController
@RequestMapping("/resignationGuidelines")
public class ResignationGuidelinesController {

    @Autowired
    private ResignationGuidelinesService guidelinesService;

    @ApiOperation(value = "列表查询")
    @PostMapping("/selectResignationGuidelinesByPage")
    public IPage<ResignationGuidelinesVo> selectResignationGuidelinesByPage(@RequestBody ResignationGuidelinesReq req){
        return guidelinesService.selectResignationGuidelinesByPage(req);
    }

    @PostMapping("/saveOrUpdateResignationGuidelines")
    public void saveOrUpdateResignationGuidelines(@RequestBody ResignationGuidelinesReq req){
        guidelinesService.saveOrUpdateResignationGuidelines(req);
    }
}
